package com.situ.week1.day4;

import org.junit.Test;

import java.util.ArrayList;

public class CollectionDemo {
    @Test
    public void test1() {
        Student[] array = new Student[3];

        ArrayList<Student> list = new ArrayList();
        Student student1 = new Student();
        Student student2 = new Student();
        Student student3 = new Student();
        Student student4 = new Student();
        list.add(student1);
        list.add(student2);
        list.add(student3);
        list.add(student4);
        for (Student student : list) {
            System.out.println(student);
        }
    }
}
